import Layout from '@/layout'
import EmptyLayout from '@/layout/empty'

export default [
    {
        path: '/pages_example/general',
        component: Layout,
        redirect: '/pages_example/general/manager',
        name: 'pagesExampleGeneral',
        meta: {
            title: '通用',
            icon: 'ri-function-line'
        },
        children: [
            {
                path: 'manager',
                name: 'pagesExampleGeneralManager',
                component: EmptyLayout,
                redirect: '/pages_example/general/manager',
                meta: {
                    title: '管理员管理'
                },
                children: [
                    {
                        path: '',
                        name: 'pagesExampleGeneralManagerList',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/manager/list'),
                        meta: {
                            title: '管理员列表',
                            sidebar: false,
                            breadcrumb: false
                        }
                    },
                    {
                        path: 'detail',
                        name: 'pagesExampleGeneralManagerCreate',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/manager/detail'),
                        meta: {
                            title: '新增管理员',
                            sidebar: false,
                            activeMenu: '/pages_example/general/manager'
                        }
                    },
                    {
                        path: 'detail/:id',
                        name: 'pagesExampleGeneralManagerEdit',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/manager/detail'),
                        meta: {
                            title: '编辑管理员',
                            sidebar: false,
                            activeMenu: '/pages_example/general/manager'
                        }
                    }
                ]
            },
            {
                path: 'department',
                name: 'pagesExampleGeneralDepartment',
                component: EmptyLayout,
                redirect: '/pages_example/general/department',
                meta: {
                    title: '部门管理'
                },
                children: [
                    {
                        path: '',
                        name: 'pagesExampleGeneralDepartmentList',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/department/list'),
                        meta: {
                            title: '部门列表',
                            sidebar: false,
                            breadcrumb: false
                        }
                    },
                    {
                        path: 'detail',
                        name: 'pagesExampleGeneralDepartmentCreate',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/department/detail'),
                        meta: {
                            title: '新增部门',
                            sidebar: false,
                            activeMenu: '/pages_example/general/department'
                        }
                    },
                    {
                        path: 'detail/:id',
                        name: 'pagesExampleGeneralDepartmentEdit',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/department/detail'),
                        meta: {
                            title: '编辑部门',
                            sidebar: false,
                            activeMenu: '/pages_example/general/department'
                        }
                    },
                    {
                        path: ':department_id/job',
                        name: 'pagesExampleGeneralJob',
                        component: EmptyLayout,
                        meta: {
                            title: '职位管理',
                            sidebar: false
                        },
                        children: [
                            {
                                path: '',
                                name: 'pagesExampleGeneralJobList',
                                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/department/job/list'),
                                meta: {
                                    title: '职位列表',
                                    sidebar: false,
                                    breadcrumb: false,
                                    activeMenu: '/pages_example/general/department'
                                }
                            },
                            {
                                path: 'detail',
                                name: 'pagesExampleGeneralJobCreate',
                                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/department/job/detail'),
                                meta: {
                                    title: '新增职位',
                                    sidebar: false,
                                    activeMenu: '/pages_example/general/department'
                                }
                            },
                            {
                                path: 'detail/:id',
                                name: 'pagesExampleGeneralJobEdit',
                                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/department/job/detail'),
                                meta: {
                                    title: '编辑职位',
                                    sidebar: false,
                                    activeMenu: '/pages_example/general/department'
                                }
                            }
                        ]
                    }
                ]
            },
            {
                path: 'permission',
                name: 'pagesExampleGeneralPermission',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/permission'),
                meta: {
                    title: '权限'
                }
            }
        ]
    },
    {
        path: '/pages_example/form',
        component: Layout,
        redirect: '/pages_example/form/basic',
        name: 'pagesExampleForm',
        meta: {
            title: '表单',
            icon: 'ri-file-list-2-line'
        },
        children: [
            {
                path: 'basic',
                name: 'pagesExampleFormBasic',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/form/basic'),
                meta: {
                    title: '基础表单'
                }
            },
            {
                path: 'advanced',
                name: 'pagesExampleFormAdvanced',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/form/advanced'),
                meta: {
                    title: '高级表单'
                }
            },
            {
                path: 'step',
                name: 'pagesExampleFormStep',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/form/step'),
                meta: {
                    title: '分步表单'
                }
            }
        ]
    },
    {
        path: '/pages_example/list',
        component: Layout,
        redirect: '/pages_example/list/basic',
        name: 'pagesExampleList',
        meta: {
            title: '列表',
            icon: 'ri-grid-line'
        },
        children: [
            {
                path: 'basic',
                name: 'pagesExampleListBasic',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/list/basic'),
                meta: {
                    title: '基础列表'
                }
            },
            {
                path: 'card',
                name: 'pagesExampleListCard',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/list/card'),
                meta: {
                    title: '卡片列表'
                }
            },
            {
                path: 'goods',
                name: 'pagesExampleListGoods',
                component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/list/goods'),
                meta: {
                    title: '商品列表'
                }
            }
        ]
    },
    {
        path: '/pages_example/shop',
        component: Layout,
        redirect: '/pages_example/shop/delivery',
        name: 'pagesExampleShop',
        meta: {
            title: '电商',
            icon: 'sidebar-shop'
        },
        children: [
            {
                path: 'delivery',
                name: 'pagesExampleShopDelivery',
                component: EmptyLayout,
                redirect: '/pages_example/shop/delivery',
                meta: {
                    title: '运费模版管理'
                },
                children: [
                    {
                        path: '',
                        name: 'pagesExampleShopDeliveryList',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/delivery/list'),
                        meta: {
                            title: '运费模版列表',
                            sidebar: false,
                            breadcrumb: false
                        }
                    },
                    {
                        path: 'detail',
                        name: 'pagesExampleShopDeliveryCreate',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/delivery/detail'),
                        meta: {
                            title: '新增运费模版',
                            sidebar: false,
                            activeMenu: '/pages_example/shop/delivery'
                        }
                    },
                    {
                        path: 'detail/:id',
                        name: 'pagesExampleShopDeliveryEdit',
                        component: () => import(/* webpackChunkName: 'pages_example' */ '@/views/pages_example/delivery/detail'),
                        meta: {
                            title: '编辑运费模版',
                            sidebar: false,
                            activeMenu: '/pages_example/shop/delivery'
                        }
                    }
                ]
            }
        ]
    }
]
